﻿
namespace ArienToolkits.Validator
{
    public static class RegexExpressions
    {
        /// <summary>
        /// 手机号码
        /// 可以使用13、14、15、18开头，并且长度必须是11位
        /// </summary>
        public const string MobilePhoneNumberPartten = @"^(13|14|15|18)\d{9}$";

        /// <summary>
        /// 正整数
        /// </summary>
        public const string PositiveIntegerPartten = @"^\d+$";

        /// <summary>
        /// 电子邮件
        /// </summary>
        public const string EmailPartten = @"^(\w)+(\.\w+)*@(\w)+((\.\w{2,3}){1,3})$";

        /// <summary>
        /// 中文姓名
        /// </summary>
        public const string CompellationPartten = @"^[\u4E00-\u9FA5]{2,5}(?:·[\u4E00-\u9FA5]{2,5})*$";

        /// <summary>
        /// 身份证号
        /// </summary>
        public const string PassportIDPartten = @"^(\d{15}$|^\d{18}$|^\d{17}(\d|X|x))$";

        /// <summary>
        /// IP地址
        /// </summary>
        public const string IPAddressPartten = @"^\d{1,3}[\.]\d{1,3}[\.]\d{1,3}[\.]\d{1,3}$";

        /// <summary>
        /// QQ号码
        /// </summary>
        public const string QQNumberPartten = @"^[1-9][0-9]{4,}$";

        /// <summary>
        /// 邮政编码
        /// </summary>
        public const string ZipCodePartten = @"^[1-9]\d{5}(?!\d)$";
    }
}
